<article class="" id="post-">
<header class="entry-header">
<h1 class="entry-title">.jquery</h1>
<div class="entry-meta">
						所属分类：<span class="category"><a href="/category/internals/">内部函数</a></span><span class="category-divider"> | </span><span class="category"><a href="/category/properties/">内部属性</a> &gt; <a href="/category/properties/jquery-object-instance-properties/">jQuery 对象实例的属性</a></span>
<span class="pull-right">英文文档：<a href="https://api.jquery123.com/jquery-2/" target="_blank">.jquery</a></span>
</div><!-- .entry-meta -->
</header><!-- .entry-header -->
<!-- .entry-header -->
<div class="entry-content">
<article class="entry property" id="jquery1"><h2 class="section-title">
<span>jquery</span><span class="returns">返回: <a href="/Types/#String">String</a></span>
</h2>
<div class="entry-wrapper">
<p class="desc"><strong>描述: </strong>一个包含了jQuery版本号的字符串。</p>
<ul class="signatures"><li class="signature"><h4 class="name">
<span class="version-details">添加的版本: <a href="/category/version/1.0/">1.0</a></span>jquery</h4></li></ul>
<div class="longdesc" id="entry-longdesc">
<p>
<code>.jquery</code>原型指向jQuery的原型， 通常被称为它的别名<code>$.fn</code>。它是一个字符串，其中包含的jQuery的版本号，如“1.5.0”或“1.4.4”。
			    </p>
</div>
<section class="entry-examples" id="entry-examples"><header><h2 class="underline">例子:</h2></header><div class="entry-example" id="example-0">
<h4>Example: <span class="desc">Determine if an object is a jQuery object</span>
</h4>
<div class="syntaxhighlighter javascript ">
<table>
<tbody>
<tr>
<td class="gutter">
<div class="line n1">1</div>
<div class="line n2">2</div>
<div class="line n3">3</div>
<div class="line n4">4</div>
<div class="line n5">5</div>
<div class="line n6">6</div>
<div class="line n7">7</div>
<div class="line n8">8</div>
<div class="line n9">9</div>
<div class="line n10">10</div>
</td>
<td class="code">
<pre><div class="container"><div class="line"><code><span class="keyword">var</span> a = { what: <span class="string">"A regular JS object"</span> },</code></div></div><div class="container"><div class="line"><code>    b = $(<span class="string">'body'</span>);</code></div></div><div class="container"><div class="line"><code> </code></div></div><div class="container"><div class="line"><code><span class="keyword">if</span> ( a.jquery ) { <span class="comment">// falsy, since it's undefined</span></code></div></div><div class="container"><div class="line"><code>    alert(<span class="string">' a is a jQuery object! '</span>);</code></div></div><div class="container"><div class="line"><code>}</code></div></div><div class="container"><div class="line"><code> </code></div></div><div class="container"><div class="line"><code><span class="keyword">if</span> ( b.jquery ) { <span class="comment">// truthy, since it's a string</span></code></div></div><div class="container"><div class="line"><code>    alert(<span class="string">' b is a jQuery object! '</span>);</code></div></div><div class="container"><div class="line"><code>}</code></div></div></pre>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="entry-example" id="example-1">
<h4>Example: <span class="desc">Get the current version of jQuery running on the page</span>
</h4>
<div class="syntaxhighlighter javascript ">
<table>
<tbody>
<tr>
<td class="gutter">
<div class="line n1">1</div>
</td>
<td class="code">
<pre><div class="container"><div class="line"><code>alert( <span class="string">'You are running jQuery version: '</span> + $.fn.jquery );</code></div></div></pre>
</td>
</tr>
</tbody>
</table>
</div>
</div></section>
</div></article> </div>
</article>